import Vue from "vue";
import App from "./App.vue";
import router from "./router";
import store from "./store";

//引入全局守卫
import './router/permision.js'
// css reset
import "./style/cssreset.css";
import "./style/public.less";
//引入 iconfont图标
import "./iconfont/iconfont.css";
import "./iconfont/font/iconfont.css";
//引入 i18n
import VueI18n from 'vue-i18n'

import ElementUI from "element-ui";
import "element-ui/lib/theme-chalk/index.css";
// element ui样式重置
import "./style/elreset.less";
Vue.use(ElementUI);
Vue.use(VueI18n)
Vue.config.productionTip = false;

//创建 i18n实例
const i18n = new VueI18n({
  locale:store.getters.locale,
  messages:{
    "zh":require('./lang/zh'),
    "en":require('./lang/en')
  }
})

new Vue({
  i18n,
  router,
  store,
  render: (h) => h(App),
}).$mount("#app");
